<?php

namespace Cours\UserBundle\Form\Type;

use Symfony\Component\Form\FormBuilderInterface;
use FOS\UserBundle\Form\Type\RegistrationFormType as BaseType;

class RegistrationFormType extends BaseType
{
    public function buildForm(FormBuilderInterface $builder, array $options)
    {
        parent::buildForm($builder, $options);

        // add your custom field
        $builder->add('promotion', 'entity', array(
            'class' => 'CoursQuizzBundle:Promotion', 'property' => 'libelle', 'multiple' => false));
    }

    public function getName()
    {
        return 'cours_user_registration';
    }
}